using SS.core;
using System;
using System.ComponentModel;
using System.Data;
using System.Data.SqlClient;
using System.Drawing;
using System.Globalization;
using System.Threading;
using System.Windows.Forms;
namespace SS
{
	public class FrmupdtCustomer : Form
	{
		public string _Customer_ID = string.Empty;
		public string strConnection = "";
		public string _Provider_ID = string.Empty;
		private customers objC = new customers();
		private Func objFunc = new Func();
		public bool IsBanLe = true;
		public string IDofNewCus = "";
		public string NameofNewCus = "";
		public string AutoIDofNewCus = "0";
		public string TypeOfNewCus = "";
		public bool AddFromRep = false;
		private IContainer components = null;
		private ComboBox cbbGCustomer_ID;
		private TextBox txtGCustomer_Notes;
		private TextBox txtID;
		private Label label4;
		private Label label3;
		private Label label6;
		private Label label7;
		private Label label8;
		private TextBox txtFax;
		private Label label9;
		private Label label10;
		private TextBox txtEmail;
		private TextBox txtTax;
		private GroupBox groupBox1;
		private Button tSBClose;
		private Button tSBSave;
		private Button btnDel;
		private Label label2;
		private ComboBox cbbCustomerType;
		private Label label5;
		private MaskedTextBox txtHasBalance;
		private Label label16;
		private TextBox txtRepUnpaid;
		private Label label11;
		private Label lblCount;
		private TextBox textBox1;
		private CheckBox ckbSameCustomers;
		private TextBox txtProID;
		private Button btnAddNewGroupCus;
		public TextBox txtPhone;
		public Button tSBAdd;
		public TextBox txtName;
		public TextBox txtAddress;
		private Button btnEdit;
		private DataGridView dgvCustomer;
		private Label label1;
		private DataGridViewTextBoxColumn Column1;
		private DataGridViewTextBoxColumn Column2;
		private DataGridViewTextBoxColumn Column3;
		private DataGridViewTextBoxColumn Column4;
		private BindingNavigator bindingNavigator1;
		private ToolStripLabel bindingNavigatorCountItem;
		private ToolStripButton bindingNavigatorMoveFirstItem;
		private ToolStripButton bindingNavigatorMovePreviousItem;
		private ToolStripSeparator bindingNavigatorSeparator;
		private ToolStripTextBox bindingNavigatorPositionItem;
		private ToolStripSeparator bindingNavigatorSeparator1;
		private ToolStripButton bindingNavigatorMoveNextItem;
		private ToolStripButton bindingNavigatorMoveLastItem;
		private ToolStripSeparator bindingNavigatorSeparator2;
		public FrmupdtCustomer()
		{
			this.InitializeComponent();
			Program.strConnectionString = this.objFunc.strConnectionString;
		}
		private void frmupdtCustomer_Load(object sender, EventArgs e)
		{
			Thread.CurrentThread.CurrentCulture = new CultureInfo("en-us");
			this.objC.loadToDataGridView(this.dgvCustomer, this.bindingNavigator1);
			this.lblCount.Text = "Hiện có " + this.dgvCustomer.Rows.Count.ToString() + " khách hàng trên hệ thống";
			this.objFunc.LoadComboBox("SELECT [GCustomer_ID], [GCustomer_Name] FROM [TabGroupCustomer] ORDER BY [GCustomer_Name]", this.cbbGCustomer_ID, "GCustomer_ID", "GCustomer_Name");
			this.txtName.Focus();
		}
		private bool CheckName(string tempName, string tempCusID)
		{
			bool result = false;
			SqlConnection sqlConnection = new SqlConnection(Program.strConnectionString);
			SqlCommand sqlCommand = new SqlCommand();
			sqlCommand.Connection = sqlConnection;
			sqlCommand.CommandText = string.Concat(new string[]
			{
				"SELECT TOP 1 Name FROM [TabPartner] WHERE [Name] = '",
				tempName,
				"' AND [CusID]<>'' AND [CusID]<>'",
				tempCusID,
				"' "
			});
			sqlConnection.Open();
			SqlDataReader sqlDataReader = sqlCommand.ExecuteReader();
			if (sqlDataReader.HasRows)
			{
				result = true;
			}
			sqlDataReader.Close();
			sqlDataReader.Dispose();
			sqlConnection.Close();
			sqlConnection.Dispose();
			return result;
		}
		private void customerAction()
		{
			try
			{
				SqlConnection sqlConnection = new SqlConnection(Program.strConnectionString);
				SqlCommand sqlCommand = new SqlCommand("ActionOnTabPartnerAsCustomer", sqlConnection);
				sqlCommand.CommandType = CommandType.StoredProcedure;
				sqlCommand.Parameters.Add("@CusID", SqlDbType.VarChar, 50);
				sqlCommand.Parameters.Add("@Name", SqlDbType.NVarChar, 200);
				sqlCommand.Parameters.Add("@Address", SqlDbType.NVarChar, 500);
				sqlCommand.Parameters.Add("@Phone", SqlDbType.VarChar, 50);
				sqlCommand.Parameters.Add("@Fax", SqlDbType.VarChar, 50);
				sqlCommand.Parameters.Add("@Email", SqlDbType.VarChar, 50);
				sqlCommand.Parameters.Add("@Tax", SqlDbType.VarChar, 50);
				sqlCommand.Parameters.Add("@CusGroup", SqlDbType.VarChar, 50);
				sqlCommand.Parameters.Add("@IsProvider", SqlDbType.SmallInt);
				sqlCommand.Parameters["@CusID"].Value = this.txtID.Text.Trim().ToUpper();
				sqlCommand.Parameters["@Name"].Value = this.txtName.Text;
				sqlCommand.Parameters["@Address"].Value = this.txtAddress.Text;
				sqlCommand.Parameters["@Phone"].Value = this.txtPhone.Text;
				sqlCommand.Parameters["@Fax"].Value = this.txtFax.Text;
				sqlCommand.Parameters["@Email"].Value = this.txtEmail.Text;
				sqlCommand.Parameters["@Tax"].Value = this.txtTax.Text;
				sqlCommand.Parameters["@CusGroup"].Value = this.cbbGCustomer_ID.SelectedValue;
				if (this.ckbSameCustomers.Checked)
				{
					sqlCommand.Parameters["@IsProvider"].Value = 1;
				}
				else
				{
					sqlCommand.Parameters["@IsProvider"].Value = 0;
				}
				sqlConnection.Open();
				sqlCommand.ExecuteNonQuery();
				sqlConnection.Close();
				sqlConnection.Dispose();
			}
			catch
			{
				MessageBox.Show("Có lỗi xảy ra trong khi lưu thông tin !", "Thông báo", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
			}
		}
		private void tSBSave_Click(object sender, EventArgs e)
		{
			if (this.txtName.Text != string.Empty && this.cbbGCustomer_ID.SelectedIndex >= 0)
			{
				this.customerAction();
				this.objC.loadToDataGridView(this.dgvCustomer, this.bindingNavigator1);
				this.lblCount.Text = "Hiện có " + this.dgvCustomer.Rows.Count.ToString() + " khách hàng trên hệ thống";
				this.tSBSave.Enabled = false;
				this.btnEdit.Enabled = true;
			}
			else
			{
				MessageBox.Show("Xin vui lòng điền đầy đủ thông tin cần thiết!", "Thông báo", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
			}
		}
		private void tSBAdd_Click(object sender, EventArgs e)
		{
			this.txtID.Text = "NEW";
			this.txtName.Text = "";
			this.txtAddress.Text = "";
			this.txtPhone.Text = "";
			this.txtEmail.Text = "";
			this.txtFax.Text = "";
			this.txtTax.Text = "";
			this.txtGCustomer_Notes.Text = "";
			this.cbbGCustomer_ID.SelectedIndex = 0;
			this.ckbSameCustomers.Checked = false;
			this._Customer_ID = "-:-";
			this.txtProID.Text = "";
			this.tSBSave.Enabled = true;
			this.btnEdit.Enabled = false;
			this.txtName.Focus();
		}
		private void txtID_Enter(object sender, EventArgs e)
		{
			this.txtID.BackColor = Color.Aqua;
		}
		private void txtName_Enter(object sender, EventArgs e)
		{
			this.txtName.BackColor = Color.Aqua;
		}
		private void txtAddress_Enter(object sender, EventArgs e)
		{
			this.txtAddress.BackColor = Color.Aqua;
		}
		private void cbbGCustomer_ID_Enter(object sender, EventArgs e)
		{
			this.cbbGCustomer_ID.BackColor = Color.Aqua;
		}
		private void txtPhone_Enter(object sender, EventArgs e)
		{
			this.txtPhone.BackColor = Color.Aqua;
		}
		private void txtFax_Enter(object sender, EventArgs e)
		{
			this.txtFax.BackColor = Color.Aqua;
		}
		private void txtEmail_Enter(object sender, EventArgs e)
		{
			this.txtEmail.BackColor = Color.Aqua;
		}
		private void txtTax_Enter(object sender, EventArgs e)
		{
			this.txtTax.BackColor = Color.Aqua;
		}
		private void txtGCustomer_Notes_Enter(object sender, EventArgs e)
		{
			this.txtGCustomer_Notes.BackColor = Color.Aqua;
		}
		private void txtID_KeyPress(object sender, KeyPressEventArgs e)
		{
			if (e.KeyChar == '\r')
			{
				this.txtName.Focus();
			}
		}
		private void txtName_KeyPress(object sender, KeyPressEventArgs e)
		{
			if (e.KeyChar == '\r')
			{
				this.txtAddress.Focus();
			}
		}
		private void txtAddress_KeyPress(object sender, KeyPressEventArgs e)
		{
			if (e.KeyChar == '\r')
			{
				this.cbbGCustomer_ID.Focus();
			}
		}
		private void cbbGCustomer_ID_KeyPress(object sender, KeyPressEventArgs e)
		{
			if (e.KeyChar == '\r')
			{
				this.txtPhone.Focus();
			}
		}
		private void txtPhone_KeyPress(object sender, KeyPressEventArgs e)
		{
			if (e.KeyChar == '\r')
			{
				this.txtFax.Focus();
			}
		}
		private void txtEmail_KeyPress(object sender, KeyPressEventArgs e)
		{
			if (e.KeyChar == '\r')
			{
				this.txtTax.Focus();
			}
		}
		private void txtFax_KeyPress(object sender, KeyPressEventArgs e)
		{
			if (e.KeyChar == '\r')
			{
				this.txtEmail.Focus();
			}
		}
		private void txtTax_KeyPress(object sender, KeyPressEventArgs e)
		{
			if (e.KeyChar == '\r')
			{
				this.txtGCustomer_Notes.Focus();
			}
		}
		private void txtID_Leave(object sender, EventArgs e)
		{
			this.txtID.BackColor = Color.White;
		}
		private void txtName_Leave(object sender, EventArgs e)
		{
			this.txtName.BackColor = Color.White;
		}
		private void txtAddress_Leave(object sender, EventArgs e)
		{
			this.txtAddress.BackColor = Color.White;
		}
		private void cbbGCustomer_ID_Leave(object sender, EventArgs e)
		{
			this.cbbGCustomer_ID.BackColor = Color.White;
		}
		private void txtPhone_Leave(object sender, EventArgs e)
		{
			this.txtPhone.BackColor = Color.White;
		}
		private void txtFax_Leave(object sender, EventArgs e)
		{
			this.txtFax.BackColor = Color.White;
		}
		private void txtEmail_Leave(object sender, EventArgs e)
		{
			this.txtEmail.BackColor = Color.White;
		}
		private void txtTax_Leave(object sender, EventArgs e)
		{
			this.txtTax.BackColor = Color.White;
		}
		private void txtGCustomer_Notes_Leave(object sender, EventArgs e)
		{
			this.txtGCustomer_Notes.BackColor = Color.White;
		}
		private void tSBClose_Click(object sender, EventArgs e)
		{
			base.Close();
		}
		private void btnDel_Click(object sender, EventArgs e)
		{
			try
			{
				if (MessageBox.Show("Có phải bạn muốn xoá khách hàng  được chọn không?\r\n\r\nBấm YES nếu đồng ý xoá, Bấm NO để bỏ qua!", "Thông báo", MessageBoxButtons.YesNo, MessageBoxIcon.Question) == DialogResult.Yes)
				{
					if (this.CheckPartnerExistInOutBill(this._Customer_ID) || this.CheckPartnerExistInBill(this._Customer_ID))
					{
						MessageBox.Show("Khách hàng  \"" + this.txtName.Text + "\" đã có giao dịch ở các hóa đơn.\r\n\r\nBạn không thể xoá khách hàng hiện tại khỏi hệ thống!", "Thông báo", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
						this.objC.loadToDataGridView(this.dgvCustomer, this.bindingNavigator1);
						this.lblCount.Text = "Hiện có " + this.dgvCustomer.Rows.Count.ToString() + " khách hàng trên hệ thống";
					}
					else
					{
						this.objC.del(this._Customer_ID);
						this.objC.loadToDataGridView(this.dgvCustomer, this.bindingNavigator1);
						this.lblCount.Text = "Hiện có " + this.dgvCustomer.Rows.Count.ToString() + " khách hàng trên hệ thống";
					}
				}
			}
			catch
			{
			}
		}
		private bool CheckPartnerExistInOutBill(string tmpAutoID)
		{
			bool result = false;
			SqlConnection sqlConnection = new SqlConnection(Program.strConnectionString);
			sqlConnection.Open();
			try
			{
				SqlCommand sqlCommand = sqlConnection.CreateCommand();
				sqlCommand.CommandText = "SELECT [ID] FROM [TabInOutBill] WHERE [ObjectID] = '" + tmpAutoID + "'";
				SqlDataReader sqlDataReader = sqlCommand.ExecuteReader();
				if (sqlDataReader.HasRows)
				{
					result = true;
				}
				sqlDataReader.Close();
				sqlDataReader.Dispose();
			}
			catch
			{
			}
			sqlConnection.Close();
			sqlConnection.Dispose();
			return result;
		}
		private bool CheckPartnerExistInBill(string tmpAutoID)
		{
			bool result = false;
			SqlConnection sqlConnection = new SqlConnection(Program.strConnectionString);
			sqlConnection.Open();
			try
			{
				SqlCommand sqlCommand = sqlConnection.CreateCommand();
				sqlCommand.CommandText = "SELECT [ID] FROM [TabBill] WHERE [PID] = '" + tmpAutoID + "'";
				SqlDataReader sqlDataReader = sqlCommand.ExecuteReader();
				if (sqlDataReader.HasRows)
				{
					result = true;
				}
				sqlDataReader.Close();
				sqlDataReader.Dispose();
			}
			catch
			{
			}
			sqlConnection.Close();
			sqlConnection.Dispose();
			return result;
		}
		private string CheckPartnerExistinCusTrade(string tmpAutoID)
		{
			string text = "";
			SqlConnection sqlConnection = new SqlConnection(Program.strConnectionString);
			sqlConnection.Open();
			try
			{
				SqlCommand sqlCommand = sqlConnection.CreateCommand();
				sqlCommand.CommandText = "SELECT TOP 2 [ID] FROM TabBill WHERE [PID] = '" + tmpAutoID + "'";
				SqlDataReader sqlDataReader = sqlCommand.ExecuteReader();
				int num = 1;
				if (sqlDataReader.HasRows)
				{
					while (sqlDataReader.Read())
					{
						if (num == 1)
						{
							text += sqlDataReader["ID"].ToString();
							num = 2;
						}
						else
						{
							text = text + "," + sqlDataReader["ID"].ToString();
						}
					}
				}
				sqlDataReader.Close();
				sqlDataReader.Dispose();
			}
			catch
			{
			}
			sqlConnection.Close();
			sqlConnection.Dispose();
			return text;
		}
		private void btnAddNewGroupCus_Click(object sender, EventArgs e)
		{
			try
			{
				FrmudtGroupCustomer frmudtGroupCustomer = new FrmudtGroupCustomer();
				frmudtGroupCustomer.ShowDialog();
				this.cbbGCustomer_ID.DataSource = null;
				this.cbbGCustomer_ID.Items.Clear();
				this.objFunc.LoadComboBox("SELECT [GCustomer_ID], [GCustomer_Name] FROM [TabGroupCustomer] ORDER BY [GCustomer_Name]", this.cbbGCustomer_ID, "GCustomer_ID", "GCustomer_Name");
			}
			catch (Exception ex)
			{
				MessageBox.Show(ex.ToString());
			}
		}
		private void FrmupdtCustomer_KeyDown(object sender, KeyEventArgs e)
		{
			if (e.KeyCode == Keys.F4)
			{
				this.tSBAdd.PerformClick();
			}
			else
			{
				if (e.KeyCode == Keys.F5)
				{
					this.btnEdit.PerformClick();
				}
				else
				{
					if (e.KeyCode == Keys.F6)
					{
						this.tSBSave.PerformClick();
					}
					else
					{
						if (e.KeyCode == Keys.F8)
						{
							this.btnDel.PerformClick();
						}
						else
						{
							if (e.KeyCode == Keys.F9)
							{
								this.tSBClose.PerformClick();
							}
							else
							{
								if (e.KeyCode == Keys.Escape)
								{
									base.Close();
								}
							}
						}
					}
				}
			}
		}
		private void btnEdit_Click(object sender, EventArgs e)
		{
			this.tSBSave.Enabled = true;
		}
		private void dgvGCustomer_CellEnter(object sender, DataGridViewCellEventArgs e)
		{
			try
			{
				this._Customer_ID = this.dgvCustomer.Rows[e.RowIndex].Cells["Column1"].Value.ToString();
				this.objC.getInfo(this._Customer_ID, this.txtID, this.cbbGCustomer_ID, this.txtName, this.txtAddress, this.txtPhone, this.txtFax, this.txtEmail, this.txtTax, this.cbbCustomerType, this.ckbSameCustomers);
				this.tSBSave.Enabled = false;
				this.btnEdit.Enabled = true;
			}
			catch
			{
			}
		}
		protected override void Dispose(bool disposing)
		{
			if (disposing && this.components != null)
			{
				this.components.Dispose();
			}
			base.Dispose(disposing);
		}
		private void InitializeComponent()
		{
			this.components = new Container();
			ComponentResourceManager componentResourceManager = new ComponentResourceManager(typeof(FrmupdtCustomer));
			DataGridViewCellStyle dataGridViewCellStyle = new DataGridViewCellStyle();
			this.cbbGCustomer_ID = new ComboBox();
			this.txtName = new TextBox();
			this.txtGCustomer_Notes = new TextBox();
			this.txtID = new TextBox();
			this.label4 = new Label();
			this.label3 = new Label();
			this.label6 = new Label();
			this.txtAddress = new TextBox();
			this.label7 = new Label();
			this.txtPhone = new TextBox();
			this.label8 = new Label();
			this.txtFax = new TextBox();
			this.label9 = new Label();
			this.label10 = new Label();
			this.txtEmail = new TextBox();
			this.txtTax = new TextBox();
			this.groupBox1 = new GroupBox();
			this.btnAddNewGroupCus = new Button();
			this.label5 = new Label();
			this.ckbSameCustomers = new CheckBox();
			this.textBox1 = new TextBox();
			this.txtProID = new TextBox();
			this.txtHasBalance = new MaskedTextBox();
			this.label16 = new Label();
			this.txtRepUnpaid = new TextBox();
			this.label11 = new Label();
			this.label2 = new Label();
			this.cbbCustomerType = new ComboBox();
			this.tSBClose = new Button();
			this.tSBSave = new Button();
			this.tSBAdd = new Button();
			this.btnDel = new Button();
			this.lblCount = new Label();
			this.btnEdit = new Button();
			this.dgvCustomer = new DataGridView();
			this.Column1 = new DataGridViewTextBoxColumn();
			this.Column2 = new DataGridViewTextBoxColumn();
			this.Column3 = new DataGridViewTextBoxColumn();
			this.Column4 = new DataGridViewTextBoxColumn();
			this.label1 = new Label();
			this.bindingNavigator1 = new BindingNavigator(this.components);
			this.bindingNavigatorCountItem = new ToolStripLabel();
			this.bindingNavigatorMoveFirstItem = new ToolStripButton();
			this.bindingNavigatorMovePreviousItem = new ToolStripButton();
			this.bindingNavigatorSeparator = new ToolStripSeparator();
			this.bindingNavigatorPositionItem = new ToolStripTextBox();
			this.bindingNavigatorSeparator1 = new ToolStripSeparator();
			this.bindingNavigatorMoveNextItem = new ToolStripButton();
			this.bindingNavigatorMoveLastItem = new ToolStripButton();
			this.bindingNavigatorSeparator2 = new ToolStripSeparator();
			this.groupBox1.SuspendLayout();
			((ISupportInitialize)this.dgvCustomer).BeginInit();
			((ISupportInitialize)this.bindingNavigator1).BeginInit();
			this.bindingNavigator1.SuspendLayout();
			base.SuspendLayout();
			this.cbbGCustomer_ID.Cursor = Cursors.Hand;
			this.cbbGCustomer_ID.DropDownStyle = ComboBoxStyle.DropDownList;
			this.cbbGCustomer_ID.FlatStyle = FlatStyle.Flat;
			this.cbbGCustomer_ID.Font = new Font("Arial", 9f, FontStyle.Regular, GraphicsUnit.Point, 163);
			this.cbbGCustomer_ID.FormattingEnabled = true;
			this.cbbGCustomer_ID.Location = new Point(127, 74);
			this.cbbGCustomer_ID.Name = "cbbGCustomer_ID";
			this.cbbGCustomer_ID.Size = new Size(276, 23);
			this.cbbGCustomer_ID.TabIndex = 3;
			this.cbbGCustomer_ID.Leave += new EventHandler(this.cbbGCustomer_ID_Leave);
			this.cbbGCustomer_ID.Enter += new EventHandler(this.cbbGCustomer_ID_Enter);
			this.cbbGCustomer_ID.KeyPress += new KeyPressEventHandler(this.cbbGCustomer_ID_KeyPress);
			this.txtName.Anchor = (AnchorStyles.Top | AnchorStyles.Left | AnchorStyles.Right);
			this.txtName.Font = new Font("Arial", 9.75f, FontStyle.Regular, GraphicsUnit.Point, 163);
			this.txtName.Location = new Point(127, 17);
			this.txtName.Name = "txtName";
			this.txtName.Size = new Size(750, 22);
			this.txtName.TabIndex = 1;
			this.txtName.Leave += new EventHandler(this.txtName_Leave);
			this.txtName.KeyPress += new KeyPressEventHandler(this.txtName_KeyPress);
			this.txtName.Enter += new EventHandler(this.txtName_Enter);
			this.txtGCustomer_Notes.Font = new Font("Arial", 9.75f, FontStyle.Regular, GraphicsUnit.Point, 0);
			this.txtGCustomer_Notes.Location = new Point(464, 269);
			this.txtGCustomer_Notes.Multiline = true;
			this.txtGCustomer_Notes.Name = "txtGCustomer_Notes";
			this.txtGCustomer_Notes.Size = new Size(313, 23);
			this.txtGCustomer_Notes.TabIndex = 10;
			this.txtGCustomer_Notes.Leave += new EventHandler(this.txtGCustomer_Notes_Leave);
			this.txtGCustomer_Notes.Enter += new EventHandler(this.txtGCustomer_Notes_Enter);
			this.txtID.BackColor = Color.White;
			this.txtID.CharacterCasing = CharacterCasing.Upper;
			this.txtID.Font = new Font("Arial", 9f, FontStyle.Bold, GraphicsUnit.Point, 0);
			this.txtID.Location = new Point(134, 18);
			this.txtID.Name = "txtID";
			this.txtID.ReadOnly = true;
			this.txtID.Size = new Size(81, 21);
			this.txtID.TabIndex = 1;
			this.txtID.Visible = false;
			this.txtID.Leave += new EventHandler(this.txtID_Leave);
			this.txtID.KeyPress += new KeyPressEventHandler(this.txtID_KeyPress);
			this.txtID.Enter += new EventHandler(this.txtID_Enter);
			this.label4.AutoSize = true;
			this.label4.Location = new Point(406, 272);
			this.label4.Name = "label4";
			this.label4.Size = new Size(55, 15);
			this.label4.TabIndex = 16;
			this.label4.Text = "Ghi chú :";
			this.label3.BackColor = Color.FromArgb(255, 255, 192);
			this.label3.BorderStyle = BorderStyle.Fixed3D;
			this.label3.Location = new Point(8, 73);
			this.label3.Name = "label3";
			this.label3.Size = new Size(116, 22);
			this.label3.TabIndex = 14;
			this.label3.Text = "Nhóm khách hàng :";
			this.label3.TextAlign = ContentAlignment.MiddleRight;
			this.label6.BackColor = Color.FromArgb(255, 255, 192);
			this.label6.BorderStyle = BorderStyle.Fixed3D;
			this.label6.Location = new Point(8, 45);
			this.label6.Name = "label6";
			this.label6.Size = new Size(116, 22);
			this.label6.TabIndex = 21;
			this.label6.Text = "Địa chỉ :";
			this.label6.TextAlign = ContentAlignment.MiddleRight;
			this.txtAddress.Anchor = (AnchorStyles.Top | AnchorStyles.Left | AnchorStyles.Right);
			this.txtAddress.Font = new Font("Arial", 9.75f, FontStyle.Regular, GraphicsUnit.Point, 163);
			this.txtAddress.Location = new Point(127, 45);
			this.txtAddress.Name = "txtAddress";
			this.txtAddress.Size = new Size(750, 22);
			this.txtAddress.TabIndex = 2;
			this.txtAddress.Leave += new EventHandler(this.txtAddress_Leave);
			this.txtAddress.KeyPress += new KeyPressEventHandler(this.txtAddress_KeyPress);
			this.txtAddress.Enter += new EventHandler(this.txtAddress_Enter);
			this.label7.BackColor = Color.FromArgb(255, 255, 192);
			this.label7.BorderStyle = BorderStyle.Fixed3D;
			this.label7.Location = new Point(8, 101);
			this.label7.Name = "label7";
			this.label7.Size = new Size(116, 22);
			this.label7.TabIndex = 23;
			this.label7.Text = "Điện thoại :";
			this.label7.TextAlign = ContentAlignment.MiddleRight;
			this.txtPhone.Font = new Font("Arial", 9.75f, FontStyle.Regular, GraphicsUnit.Point, 163);
			this.txtPhone.Location = new Point(127, 102);
			this.txtPhone.Name = "txtPhone";
			this.txtPhone.Size = new Size(313, 22);
			this.txtPhone.TabIndex = 5;
			this.txtPhone.Leave += new EventHandler(this.txtPhone_Leave);
			this.txtPhone.KeyPress += new KeyPressEventHandler(this.txtPhone_KeyPress);
			this.txtPhone.Enter += new EventHandler(this.txtPhone_Enter);
			this.label8.BackColor = Color.FromArgb(255, 255, 192);
			this.label8.BorderStyle = BorderStyle.Fixed3D;
			this.label8.Location = new Point(446, 73);
			this.label8.Name = "label8";
			this.label8.Size = new Size(57, 22);
			this.label8.TabIndex = 25;
			this.label8.Text = "Số fax :";
			this.label8.TextAlign = ContentAlignment.MiddleRight;
			this.txtFax.Font = new Font("Arial", 9.75f, FontStyle.Regular, GraphicsUnit.Point, 163);
			this.txtFax.Location = new Point(505, 73);
			this.txtFax.Name = "txtFax";
			this.txtFax.Size = new Size(143, 22);
			this.txtFax.TabIndex = 6;
			this.txtFax.Leave += new EventHandler(this.txtFax_Leave);
			this.txtFax.KeyPress += new KeyPressEventHandler(this.txtFax_KeyPress);
			this.txtFax.Enter += new EventHandler(this.txtFax_Enter);
			this.label9.BackColor = Color.FromArgb(255, 255, 192);
			this.label9.BorderStyle = BorderStyle.Fixed3D;
			this.label9.Location = new Point(447, 102);
			this.label9.Name = "label9";
			this.label9.Size = new Size(56, 22);
			this.label9.TabIndex = 27;
			this.label9.Text = "Email :";
			this.label9.TextAlign = ContentAlignment.MiddleRight;
			this.label10.BackColor = Color.FromArgb(255, 255, 192);
			this.label10.BorderStyle = BorderStyle.Fixed3D;
			this.label10.Location = new Point(654, 72);
			this.label10.Name = "label10";
			this.label10.Size = new Size(78, 22);
			this.label10.TabIndex = 28;
			this.label10.Text = "Mã số thuế :";
			this.label10.TextAlign = ContentAlignment.MiddleRight;
			this.txtEmail.Font = new Font("Arial", 9.75f, FontStyle.Regular, GraphicsUnit.Point, 163);
			this.txtEmail.Location = new Point(505, 102);
			this.txtEmail.Name = "txtEmail";
			this.txtEmail.Size = new Size(227, 22);
			this.txtEmail.TabIndex = 7;
			this.txtEmail.Leave += new EventHandler(this.txtEmail_Leave);
			this.txtEmail.KeyPress += new KeyPressEventHandler(this.txtEmail_KeyPress);
			this.txtEmail.Enter += new EventHandler(this.txtEmail_Enter);
			this.txtTax.Anchor = (AnchorStyles.Top | AnchorStyles.Left | AnchorStyles.Right);
			this.txtTax.Font = new Font("Arial", 9.75f, FontStyle.Regular, GraphicsUnit.Point, 163);
			this.txtTax.Location = new Point(734, 72);
			this.txtTax.Name = "txtTax";
			this.txtTax.Size = new Size(144, 22);
			this.txtTax.TabIndex = 8;
			this.txtTax.Leave += new EventHandler(this.txtTax_Leave);
			this.txtTax.KeyPress += new KeyPressEventHandler(this.txtTax_KeyPress);
			this.txtTax.Enter += new EventHandler(this.txtTax_Enter);
			this.groupBox1.Anchor = (AnchorStyles.Bottom | AnchorStyles.Left | AnchorStyles.Right);
			this.groupBox1.BackColor = Color.Transparent;
			this.groupBox1.Controls.Add(this.btnAddNewGroupCus);
			this.groupBox1.Controls.Add(this.label5);
			this.groupBox1.Controls.Add(this.label9);
			this.groupBox1.Controls.Add(this.txtTax);
			this.groupBox1.Controls.Add(this.label6);
			this.groupBox1.Controls.Add(this.label7);
			this.groupBox1.Controls.Add(this.label10);
			this.groupBox1.Controls.Add(this.txtEmail);
			this.groupBox1.Controls.Add(this.label3);
			this.groupBox1.Controls.Add(this.txtName);
			this.groupBox1.Controls.Add(this.label8);
			this.groupBox1.Controls.Add(this.txtFax);
			this.groupBox1.Controls.Add(this.txtAddress);
			this.groupBox1.Controls.Add(this.cbbGCustomer_ID);
			this.groupBox1.Controls.Add(this.ckbSameCustomers);
			this.groupBox1.Controls.Add(this.txtPhone);
			this.groupBox1.Controls.Add(this.txtID);
			this.groupBox1.Controls.Add(this.textBox1);
			this.groupBox1.Location = new Point(7, 426);
			this.groupBox1.Name = "groupBox1";
			this.groupBox1.Size = new Size(886, 133);
			this.groupBox1.TabIndex = 29;
			this.groupBox1.TabStop = false;
			this.groupBox1.Text = "Thông tin";
			this.btnAddNewGroupCus.FlatAppearance.BorderColor = Color.FromArgb(192, 255, 255);
			this.btnAddNewGroupCus.FlatStyle = FlatStyle.Flat;
//			this.btnAddNewGroupCus.Image = (Image)componentResourceManager.GetObject("btnAddNewGroupCus.Image");
			this.btnAddNewGroupCus.Location = new Point(410, 71);
			this.btnAddNewGroupCus.Name = "btnAddNewGroupCus";
			this.btnAddNewGroupCus.Size = new Size(30, 25);
			this.btnAddNewGroupCus.TabIndex = 78;
			this.btnAddNewGroupCus.Text = "...";
			this.btnAddNewGroupCus.UseVisualStyleBackColor = true;
			this.btnAddNewGroupCus.Click += new EventHandler(this.btnAddNewGroupCus_Click);
			this.label5.BackColor = Color.FromArgb(255, 255, 192);
			this.label5.BorderStyle = BorderStyle.Fixed3D;
			this.label5.Location = new Point(8, 17);
			this.label5.Name = "label5";
			this.label5.Size = new Size(116, 22);
			this.label5.TabIndex = 31;
			this.label5.Text = "Tên khách hàng :";
			this.label5.TextAlign = ContentAlignment.MiddleRight;
			this.ckbSameCustomers.AutoSize = true;
			this.ckbSameCustomers.Font = new Font("Arial", 9f, FontStyle.Bold, GraphicsUnit.Point, 163);
			this.ckbSameCustomers.Location = new Point(737, 104);
			this.ckbSameCustomers.Name = "ckbSameCustomers";
			this.ckbSameCustomers.Size = new Size(106, 19);
			this.ckbSameCustomers.TabIndex = 9;
			this.ckbSameCustomers.Text = "Nhà cung cấp ";
			this.ckbSameCustomers.UseVisualStyleBackColor = true;
			this.textBox1.Enabled = false;
			this.textBox1.Font = new Font("Arial", 11.25f, FontStyle.Regular, GraphicsUnit.Point, 0);
			this.textBox1.Location = new Point(126, 71);
			this.textBox1.Name = "textBox1";
			this.textBox1.Size = new Size(279, 25);
			this.textBox1.TabIndex = 73;
			this.txtProID.BackColor = Color.White;
			this.txtProID.Font = new Font("Arial", 9.75f, FontStyle.Regular, GraphicsUnit.Point, 0);
			this.txtProID.ForeColor = Color.FromArgb(0, 0, 192);
			this.txtProID.Location = new Point(506, 326);
			this.txtProID.Name = "txtProID";
			this.txtProID.ReadOnly = true;
			this.txtProID.Size = new Size(258, 22);
			this.txtProID.TabIndex = 76;
			this.txtHasBalance.BackColor = SystemColors.ControlLightLight;
			this.txtHasBalance.Font = new Font("Arial", 9.75f, FontStyle.Regular, GraphicsUnit.Point, 0);
			this.txtHasBalance.ForeColor = Color.Blue;
			this.txtHasBalance.Location = new Point(321, 373);
			this.txtHasBalance.Name = "txtHasBalance";
			this.txtHasBalance.ReadOnly = true;
			this.txtHasBalance.Size = new Size(88, 22);
			this.txtHasBalance.TabIndex = 71;
			this.txtHasBalance.Text = "0";
			this.txtHasBalance.TextAlign = HorizontalAlignment.Right;
			this.label16.AutoSize = true;
			this.label16.Location = new Point(298, 376);
			this.label16.Name = "label16";
			this.label16.Size = new Size(20, 15);
			this.label16.TabIndex = 72;
			this.label16.Text = "có";
			this.txtRepUnpaid.BackColor = SystemColors.ControlLightLight;
			this.txtRepUnpaid.Font = new Font("Arial", 9.75f, FontStyle.Regular, GraphicsUnit.Point, 0);
			this.txtRepUnpaid.ForeColor = Color.Red;
			this.txtRepUnpaid.Location = new Point(206, 373);
			this.txtRepUnpaid.Name = "txtRepUnpaid";
			this.txtRepUnpaid.ReadOnly = true;
			this.txtRepUnpaid.Size = new Size(89, 22);
			this.txtRepUnpaid.TabIndex = 69;
			this.txtRepUnpaid.Text = "0";
			this.txtRepUnpaid.TextAlign = HorizontalAlignment.Right;
			this.label11.AutoSize = true;
			this.label11.Location = new Point(123, 377);
			this.label11.Name = "label11";
			this.label11.Size = new Size(81, 15);
			this.label11.TabIndex = 70;
			this.label11.Text = "Nợ hiện thời :";
			this.label2.AutoSize = true;
			this.label2.Location = new Point(461, 377);
			this.label2.Name = "label2";
			this.label2.Size = new Size(91, 15);
			this.label2.TabIndex = 30;
			this.label2.Text = "Kiểu giao dịch :";
			this.cbbCustomerType.Cursor = Cursors.Hand;
			this.cbbCustomerType.DropDownStyle = ComboBoxStyle.DropDownList;
			this.cbbCustomerType.FlatStyle = FlatStyle.Flat;
			this.cbbCustomerType.Font = new Font("Arial", 9f, FontStyle.Regular, GraphicsUnit.Point, 0);
			this.cbbCustomerType.FormattingEnabled = true;
			this.cbbCustomerType.Location = new Point(556, 372);
			this.cbbCustomerType.Name = "cbbCustomerType";
			this.cbbCustomerType.Size = new Size(217, 23);
			this.cbbCustomerType.TabIndex = 4;
			this.tSBClose.Anchor = (AnchorStyles.Bottom | AnchorStyles.Right);
			this.tSBClose.BackColor = SystemColors.ControlLight;
			this.tSBClose.Cursor = Cursors.Hand;
			this.tSBClose.FlatAppearance.BorderColor = Color.Gray;
			this.tSBClose.FlatStyle = FlatStyle.System;
			this.tSBClose.Font = new Font("Arial", 9f, FontStyle.Bold, GraphicsUnit.Point, 163);
			this.tSBClose.ImageAlign = ContentAlignment.MiddleLeft;
//			this.tSBClose.ImeMode = ImeMode.NoControl;
			this.tSBClose.Location = new Point(797, 563);
			this.tSBClose.Name = "tSBClose";
			this.tSBClose.Size = new Size(96, 30);
			this.tSBClose.TabIndex = 32;
			this.tSBClose.Text = "Thoát  [ ESC ]";
			this.tSBClose.UseVisualStyleBackColor = false;
			this.tSBClose.Click += new EventHandler(this.tSBClose_Click);
			this.tSBSave.Anchor = (AnchorStyles.Bottom | AnchorStyles.Left);
			this.tSBSave.BackColor = SystemColors.ControlLight;
			this.tSBSave.Cursor = Cursors.Hand;
			this.tSBSave.Enabled = false;
			this.tSBSave.FlatAppearance.BorderColor = Color.Gray;
			this.tSBSave.FlatStyle = FlatStyle.System;
			this.tSBSave.Font = new Font("Arial", 9f, FontStyle.Bold, GraphicsUnit.Point, 163);
			this.tSBSave.ImageAlign = ContentAlignment.MiddleLeft;
//			this.tSBSave.ImeMode = ImeMode.NoControl;
			this.tSBSave.Location = new Point(203, 563);
			this.tSBSave.Name = "tSBSave";
			this.tSBSave.Size = new Size(102, 30);
			this.tSBSave.TabIndex = 31;
			this.tSBSave.Text = "Ghi nhận  [ F6 ]";
			this.tSBSave.UseVisualStyleBackColor = false;
			this.tSBSave.Click += new EventHandler(this.tSBSave_Click);
			this.tSBAdd.Anchor = (AnchorStyles.Bottom | AnchorStyles.Left);
			this.tSBAdd.BackColor = SystemColors.ControlLight;
			this.tSBAdd.Cursor = Cursors.Hand;
			this.tSBAdd.FlatAppearance.BorderColor = Color.Gray;
			this.tSBAdd.FlatStyle = FlatStyle.System;
			this.tSBAdd.Font = new Font("Arial", 9f, FontStyle.Bold, GraphicsUnit.Point, 163);
			this.tSBAdd.ImageAlign = ContentAlignment.MiddleLeft;
			//this.tSBAdd.ImeMode = ImeMode.NoControl;
			this.tSBAdd.Location = new Point(7, 563);
			this.tSBAdd.Name = "tSBAdd";
			this.tSBAdd.Size = new Size(104, 30);
			this.tSBAdd.TabIndex = 30;
			this.tSBAdd.Text = "Thêm mới [ F4 ]";
			this.tSBAdd.UseVisualStyleBackColor = false;
			this.tSBAdd.Click += new EventHandler(this.tSBAdd_Click);
			this.btnDel.Anchor = (AnchorStyles.Bottom | AnchorStyles.Left);
			this.btnDel.BackColor = SystemColors.ControlLight;
			this.btnDel.Cursor = Cursors.Hand;
			this.btnDel.FlatAppearance.BorderColor = Color.Gray;
			this.btnDel.FlatStyle = FlatStyle.System;
			this.btnDel.Font = new Font("Arial", 9f, FontStyle.Bold, GraphicsUnit.Point, 163);
			this.btnDel.ImageAlign = ContentAlignment.MiddleLeft;
			this.btnDel.Location = new Point(306, 563);
			this.btnDel.Name = "btnDel";
			this.btnDel.Size = new Size(91, 30);
			this.btnDel.TabIndex = 48;
			this.btnDel.Text = "Xoá  bỏ [ F8 ]";
			this.btnDel.UseVisualStyleBackColor = false;
			this.btnDel.Click += new EventHandler(this.btnDel_Click);
			this.lblCount.Anchor = (AnchorStyles.Bottom | AnchorStyles.Left | AnchorStyles.Right);
			this.lblCount.BackColor = Color.Transparent;
			this.lblCount.Location = new Point(400, 566);
			this.lblCount.Name = "lblCount";
			this.lblCount.Size = new Size(391, 25);
			this.lblCount.TabIndex = 49;
			this.lblCount.Text = "-:-";
			this.lblCount.TextAlign = ContentAlignment.MiddleCenter;
			this.btnEdit.Anchor = (AnchorStyles.Bottom | AnchorStyles.Left);
			this.btnEdit.BackColor = SystemColors.ControlLight;
			this.btnEdit.Cursor = Cursors.Hand;
			this.btnEdit.FlatAppearance.BorderColor = Color.Gray;
			this.btnEdit.FlatStyle = FlatStyle.System;
			this.btnEdit.Font = new Font("Arial", 9f, FontStyle.Bold, GraphicsUnit.Point, 163);
			this.btnEdit.ImageAlign = ContentAlignment.MiddleLeft;
//			this.btnEdit.ImeMode = ImeMode.NoControl;
			this.btnEdit.Location = new Point(112, 563);
			this.btnEdit.Name = "btnEdit";
			this.btnEdit.Size = new Size(90, 30);
			this.btnEdit.TabIndex = 77;
			this.btnEdit.Text = "Sửa đổi [ F5 ]";
			this.btnEdit.UseVisualStyleBackColor = false;
			this.btnEdit.Click += new EventHandler(this.btnEdit_Click);
			this.dgvCustomer.AllowUserToAddRows = false;
			this.dgvCustomer.AllowUserToDeleteRows = false;
			this.dgvCustomer.AllowUserToResizeColumns = false;
			this.dgvCustomer.AllowUserToResizeRows = false;
			dataGridViewCellStyle.BackColor = Color.FromArgb(192, 255, 255);
			dataGridViewCellStyle.Font = new Font("Arial", 9.75f, FontStyle.Regular, GraphicsUnit.Point, 0);
			this.dgvCustomer.AlternatingRowsDefaultCellStyle = dataGridViewCellStyle;
			this.dgvCustomer.Anchor = (AnchorStyles.Top | AnchorStyles.Bottom | AnchorStyles.Left | AnchorStyles.Right);
			this.dgvCustomer.BackgroundColor = Color.White;
			this.dgvCustomer.BorderStyle = BorderStyle.Fixed3D;
			this.dgvCustomer.ColumnHeadersHeight = 26;
			this.dgvCustomer.ColumnHeadersHeightSizeMode = DataGridViewColumnHeadersHeightSizeMode.DisableResizing;
			this.dgvCustomer.Columns.AddRange(new DataGridViewColumn[]
			{
				this.Column1,
				this.Column2,
				this.Column3,
				this.Column4
			});
			this.dgvCustomer.Cursor = Cursors.Hand;
			this.dgvCustomer.EnableHeadersVisualStyles = false;
			this.dgvCustomer.Location = new Point(7, 39);
			this.dgvCustomer.Name = "dgvCustomer";
			this.dgvCustomer.ReadOnly = true;
			this.dgvCustomer.RowHeadersVisible = false;
			this.dgvCustomer.RowHeadersWidthSizeMode = DataGridViewRowHeadersWidthSizeMode.DisableResizing;
			this.dgvCustomer.RowTemplate.DefaultCellStyle.BackColor = Color.White;
			this.dgvCustomer.RowTemplate.DefaultCellStyle.Font = new Font("Arial", 9.75f, FontStyle.Regular, GraphicsUnit.Point, 0);
			this.dgvCustomer.SelectionMode = DataGridViewSelectionMode.FullRowSelect;
			this.dgvCustomer.Size = new Size(886, 356);
			this.dgvCustomer.TabIndex = 78;
			this.dgvCustomer.CellEnter += new DataGridViewCellEventHandler(this.dgvGCustomer_CellEnter);
			this.Column1.AutoSizeMode = DataGridViewAutoSizeColumnMode.None;
			this.Column1.DataPropertyName = "CusID";
			this.Column1.HeaderText = "Số hiệu";
			this.Column1.MinimumWidth = 120;
			this.Column1.Name = "Column1";
			this.Column1.ReadOnly = true;
			this.Column1.Width = 120;
			this.Column2.AutoSizeMode = DataGridViewAutoSizeColumnMode.None;
			this.Column2.DataPropertyName = "Name";
			this.Column2.HeaderText = "Khách hàng";
			this.Column2.MinimumWidth = 300;
			this.Column2.Name = "Column2";
			this.Column2.ReadOnly = true;
			this.Column2.Width = 300;
			this.Column3.AutoSizeMode = DataGridViewAutoSizeColumnMode.Fill;
			this.Column3.DataPropertyName = "Address";
			this.Column3.HeaderText = "Địa chỉ";
			this.Column3.MinimumWidth = 300;
			this.Column3.Name = "Column3";
			this.Column3.ReadOnly = true;
			this.Column4.AutoSizeMode = DataGridViewAutoSizeColumnMode.None;
			this.Column4.DataPropertyName = "Phone";
			this.Column4.HeaderText = "Điện thoại";
			this.Column4.MinimumWidth = 120;
			this.Column4.Name = "Column4";
			this.Column4.ReadOnly = true;
			this.Column4.Width = 120;
			this.label1.Anchor = (AnchorStyles.Top | AnchorStyles.Left | AnchorStyles.Right);
			this.label1.Font = new Font("Arial", 9f, FontStyle.Bold, GraphicsUnit.Point, 0);
			this.label1.Location = new Point(7, 12);
			this.label1.Name = "label1";
			this.label1.Size = new Size(886, 24);
			this.label1.TabIndex = 79;
			this.label1.Text = "KHÁCH HÀNG";
			this.label1.TextAlign = ContentAlignment.MiddleCenter;
			this.bindingNavigator1.AddNewItem = null;
			this.bindingNavigator1.Anchor = (AnchorStyles.Bottom | AnchorStyles.Left | AnchorStyles.Right);
			this.bindingNavigator1.AutoSize = false;
			this.bindingNavigator1.BackColor = SystemColors.ButtonFace;
			this.bindingNavigator1.CountItem = this.bindingNavigatorCountItem;
			this.bindingNavigator1.CountItemFormat = "/ {0}";
			this.bindingNavigator1.DeleteItem = null;
			this.bindingNavigator1.Dock = DockStyle.None;
			this.bindingNavigator1.Font = new Font("Arial", 9f, FontStyle.Regular, GraphicsUnit.Point, 163);
			this.bindingNavigator1.GripStyle = ToolStripGripStyle.Hidden;
			this.bindingNavigator1.Items.AddRange(new ToolStripItem[]
			{
				this.bindingNavigatorMoveFirstItem,
				this.bindingNavigatorMovePreviousItem,
				this.bindingNavigatorSeparator,
				this.bindingNavigatorPositionItem,
				this.bindingNavigatorCountItem,
				this.bindingNavigatorSeparator1,
				this.bindingNavigatorMoveNextItem,
				this.bindingNavigatorMoveLastItem,
				this.bindingNavigatorSeparator2
			});
			this.bindingNavigator1.Location = new Point(7, 398);
			this.bindingNavigator1.MoveFirstItem = this.bindingNavigatorMoveFirstItem;
			this.bindingNavigator1.MoveLastItem = this.bindingNavigatorMoveLastItem;
			this.bindingNavigator1.MoveNextItem = this.bindingNavigatorMoveNextItem;
			this.bindingNavigator1.MovePreviousItem = this.bindingNavigatorMovePreviousItem;
			this.bindingNavigator1.Name = "bindingNavigator1";
			this.bindingNavigator1.PositionItem = this.bindingNavigatorPositionItem;
			this.bindingNavigator1.RenderMode = ToolStripRenderMode.Professional;
			this.bindingNavigator1.Size = new Size(886, 25);
			this.bindingNavigator1.TabIndex = 143;
			this.bindingNavigator1.Text = "bindingNavigator1";
			this.bindingNavigatorCountItem.Name = "bindingNavigatorCountItem";
			this.bindingNavigatorCountItem.Size = new Size(28, 22);
			this.bindingNavigatorCountItem.Text = "/ {0}";
			this.bindingNavigatorCountItem.ToolTipText = "Total number of items";
			this.bindingNavigatorMoveFirstItem.DisplayStyle = ToolStripItemDisplayStyle.Image;
			//this.bindingNavigatorMoveFirstItem.Image = (Image)componentResourceManager.GetObject("bindingNavigatorMoveFirstItem.Image");
			this.bindingNavigatorMoveFirstItem.Name = "bindingNavigatorMoveFirstItem";
			this.bindingNavigatorMoveFirstItem.RightToLeftAutoMirrorImage = true;
			this.bindingNavigatorMoveFirstItem.Size = new Size(23, 22);
			this.bindingNavigatorMoveFirstItem.Text = "Move first";
			this.bindingNavigatorMovePreviousItem.DisplayStyle = ToolStripItemDisplayStyle.Image;
			//this.bindingNavigatorMovePreviousItem.Image = (Image)componentResourceManager.GetObject("bindingNavigatorMovePreviousItem.Image");
			this.bindingNavigatorMovePreviousItem.Name = "bindingNavigatorMovePreviousItem";
			this.bindingNavigatorMovePreviousItem.RightToLeftAutoMirrorImage = true;
			this.bindingNavigatorMovePreviousItem.Size = new Size(23, 22);
			this.bindingNavigatorMovePreviousItem.Text = "Move previous";
			this.bindingNavigatorSeparator.Name = "bindingNavigatorSeparator";
			this.bindingNavigatorSeparator.Size = new Size(6, 25);
			this.bindingNavigatorPositionItem.AccessibleName = "Position";
			this.bindingNavigatorPositionItem.AutoSize = false;
			this.bindingNavigatorPositionItem.BackColor = SystemColors.ButtonFace;
			this.bindingNavigatorPositionItem.Font = new Font("Arial", 9f, FontStyle.Regular, GraphicsUnit.Point, 163);
			this.bindingNavigatorPositionItem.Name = "bindingNavigatorPositionItem";
			this.bindingNavigatorPositionItem.Size = new Size(50, 21);
			this.bindingNavigatorPositionItem.Text = "0";
			this.bindingNavigatorPositionItem.TextBoxTextAlign = HorizontalAlignment.Center;
			this.bindingNavigatorPositionItem.ToolTipText = "Current position";
			this.bindingNavigatorSeparator1.Name = "bindingNavigatorSeparator1";
			this.bindingNavigatorSeparator1.Size = new Size(6, 25);
			this.bindingNavigatorMoveNextItem.DisplayStyle = ToolStripItemDisplayStyle.Image;
			//this.bindingNavigatorMoveNextItem.Image = (Image)componentResourceManager.GetObject("bindingNavigatorMoveNextItem.Image");
			this.bindingNavigatorMoveNextItem.Name = "bindingNavigatorMoveNextItem";
			this.bindingNavigatorMoveNextItem.RightToLeftAutoMirrorImage = true;
			this.bindingNavigatorMoveNextItem.Size = new Size(23, 22);
			this.bindingNavigatorMoveNextItem.Text = "Move next";
			this.bindingNavigatorMoveLastItem.DisplayStyle = ToolStripItemDisplayStyle.Image;
			//this.bindingNavigatorMoveLastItem.Image = (Image)componentResourceManager.GetObject("bindingNavigatorMoveLastItem.Image");
			this.bindingNavigatorMoveLastItem.Name = "bindingNavigatorMoveLastItem";
			this.bindingNavigatorMoveLastItem.RightToLeftAutoMirrorImage = true;
			this.bindingNavigatorMoveLastItem.Size = new Size(23, 22);
			this.bindingNavigatorMoveLastItem.Text = "Move last";
			this.bindingNavigatorSeparator2.Name = "bindingNavigatorSeparator2";
			this.bindingNavigatorSeparator2.Size = new Size(6, 25);
			base.AutoScaleDimensions = new SizeF(7f, 15f);
			//base.AutoScaleMode = AutoScaleMode.Font;
			this.BackgroundImageLayout = ImageLayout.Stretch;
			base.ClientSize = new Size(900, 600);
			base.Controls.Add(this.bindingNavigator1);
			base.Controls.Add(this.label1);
			base.Controls.Add(this.dgvCustomer);
			base.Controls.Add(this.btnEdit);
			base.Controls.Add(this.lblCount);
			base.Controls.Add(this.btnDel);
			base.Controls.Add(this.tSBClose);
			base.Controls.Add(this.tSBSave);
			base.Controls.Add(this.tSBAdd);
			base.Controls.Add(this.groupBox1);
			base.Controls.Add(this.txtGCustomer_Notes);
			base.Controls.Add(this.label4);
			base.Controls.Add(this.txtHasBalance);
			base.Controls.Add(this.label16);
			base.Controls.Add(this.txtRepUnpaid);
			base.Controls.Add(this.label11);
			base.Controls.Add(this.label2);
			base.Controls.Add(this.cbbCustomerType);
			base.Controls.Add(this.txtProID);
			this.DoubleBuffered = true;
			this.Font = new Font("Arial", 9f, FontStyle.Regular, GraphicsUnit.Point, 0);
			//base.Icon = (System.Drawing.Icon)componentResourceManager.GetObject("$this.Icon");
			//base.Icon = (Icon)componentResourceManager.GetObject("$this.Icon");
			base.KeyPreview = true;
			base.MaximizeBox = false;
			base.MinimizeBox = false;
			base.Name = "FrmupdtCustomer";
			base.ShowInTaskbar = false;
			base.StartPosition = FormStartPosition.CenterScreen;
			this.Text = "Dánh sách khách hàng";
			base.Load += new EventHandler(this.frmupdtCustomer_Load);
			base.KeyDown += new KeyEventHandler(this.FrmupdtCustomer_KeyDown);
			this.groupBox1.ResumeLayout(false);
			this.groupBox1.PerformLayout();
			((ISupportInitialize)this.dgvCustomer).EndInit();
			((ISupportInitialize)this.bindingNavigator1).EndInit();
			this.bindingNavigator1.ResumeLayout(false);
			this.bindingNavigator1.PerformLayout();
			base.ResumeLayout(false);
			base.PerformLayout();
		}
	}
}
